

//
//  ConOrReDetailGoosInfoCell.m
//  LuxuryGoods
//
//  Created by DCQ on 2018/8/6.
//  Copyright © 2018年 Future. All rights reserved.
//

#import "ConOrReDetailGoodsInfoCell.h"
#import "ConOrReDetailModel.h"

@interface ConOrReDetailGoodsInfoCell()

@property (weak, nonatomic) IBOutlet UIImageView *goodImgV;
@property (weak, nonatomic) IBOutlet UILabel *goodTitle;
@property (weak, nonatomic) IBOutlet UILabel *goodPrice;
@property (weak, nonatomic) IBOutlet UILabel *expectPriceLabel;

@property (weak, nonatomic) IBOutlet UILabel *priceLabel;

@end

@implementation ConOrReDetailGoodsInfoCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
    [self setupSubViews];
}

- (void)setupSubViews{
    
 
}

- (void)setupGoodsInfo:(ConOrReGoodsModel *)model{
    
    self.goodTitle.text = model.goods_name;
    self.expectPriceLabel.text = [NSString stringWithFormat:@"期望价格:￥%@",model.expect_price];
    self.goodPrice.text =[NSString stringWithFormat:@"平台报价:%@-%@",model.platform_min_price,model.platform_max_price];
    if (model.img_list && model.img_list.count > 0) {
        [self.goodImgV yy_setImageWithURL:[NSURL URLWithString:model.img_list.firstObject] placeholder:nil];
    }
    if (model.sale_price) {
      self.priceLabel.text = [NSString stringWithFormat:@"实际回收价:%@",model.sale_price];
    }else{
        self.priceLabel.text = @"";
    }
    
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (void)showSalePrice:(BOOL)isShow{
    
    self.priceLabel.hidden = !isShow;
}
@end
